﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Reflection;
using Esint.JudicialAuction.IDAL;
using System.Configuration;
//using Esint.PublicSafety.IDAL;
namespace Esint.JudicialAuction.Factory
{
    public partial class Factory
    {
        private static readonly string profilePath = System.Configuration.ConfigurationManager.AppSettings["profilePath"];
        // private static readonly string DLLName = System.Configuration.ConfigurationSettings.AppSettings["DLLName"];
        /// <summary>
        /// 创建基础数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBaseData CreateBaseData()
        {
            string className = profilePath + ".BaseData";
            return (IBaseData)Assembly.Load(profilePath).CreateInstance(className);
        }
        
        /// <summary>
        /// 创建[T_SYS_SQLLOG] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_sqllogData CreateSys_sqllogData()
        {
            string className = profilePath + ".Sys_sqllogData";
            return (ISys_sqllogData)Assembly.Load(profilePath).CreateInstance(className);
        }
        

        public static ICommonData CreateCommonData()
        {
            string className = profilePath + ".CommonData";
            return (ICommonData)Assembly.Load(profilePath).CreateInstance(className);
        }


        /// <summary>
        /// 创建[T_Business_ApplyJoin] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_ApplyJoinData CreateBusiness_ApplyJoinData()
        {
            string className = profilePath + ".Business_ApplyJoinData";
            return (IBusiness_ApplyJoinData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Business_Article] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_ArticleData CreateBusiness_ArticleData()
        {
            string className = profilePath + ".Business_ArticleData";
            return (IBusiness_ArticleData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Business_AssetAttachments] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_AssetAttachmentsData CreateBusiness_AssetAttachmentsData()
        {
            string className = profilePath + ".Business_AssetAttachmentsData";
            return (IBusiness_AssetAttachmentsData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Business_AssetsBasic] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_AssetsBasicData CreateBusiness_AssetsBasicData()
        {
            string className = profilePath + ".Business_AssetsBasicData";
            return (IBusiness_AssetsBasicData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Business_AuctionInfo] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_AuctionInfoData CreateBusiness_AuctionInfoData()
        {
            string className = profilePath + ".Business_AuctionInfoData";
            return (IBusiness_AuctionInfoData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Business_Court] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_CourtData CreateBusiness_CourtData()
        {
            string className = profilePath + ".Business_CourtData";
            return (IBusiness_CourtData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Business_Services] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static IBusiness_ServicesData CreateBusiness_ServicesData()
        {
            string className = profilePath + ".Business_ServicesData";
            return (IBusiness_ServicesData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_Area] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_AreaData CreateSys_AreaData()
        {
            string className = profilePath + ".Sys_AreaData";
            return (ISys_AreaData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_Code] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_CodeData CreateSys_CodeData()
        {
            string className = profilePath + ".Sys_CodeData";
            return (ISys_CodeData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_CodeMap] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_CodeMapData CreateSys_CodeMapData()
        {
            string className = profilePath + ".Sys_CodeMapData";
            return (ISys_CodeMapData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_Menu] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_MenuData CreateSys_MenuData()
        {
            string className = profilePath + ".Sys_MenuData";
            return (ISys_MenuData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_SiteConfig] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_SiteConfigData CreateSys_SiteConfigData()
        {
            string className = profilePath + ".Sys_SiteConfigData";
            return (ISys_SiteConfigData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_User] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_UserData CreateSys_UserData()
        {
            string className = profilePath + ".Sys_UserData";
            return (ISys_UserData)Assembly.Load(profilePath).CreateInstance(className);
        }

        /// <summary>
        /// 创建[T_Sys_UserPower] 数据表访问对象
        /// </summary>
        /// <returns></returns>
        public static ISys_UserPowerData CreateSys_UserPowerData()
        {
            string className = profilePath + ".Sys_UserPowerData";
            return (ISys_UserPowerData)Assembly.Load(profilePath).CreateInstance(className);
        }
    }
}
